import Vue from 'vue'
import VueRouter from 'vue-router'
import Home from '../views/Home/index.vue'  //首页
import Login from '../views/Login'  //登录
import newHouse from '../views/newHouse'  //新房
import twoHouse from '../views/twoHouse'  //二手房
import rent from '../views/rent'  //出租房
import Detail from '../views/Detail'  //新房详情
import map from '../views/map'  //地图找房
import message from '../views/homeList/message'  //消息
import soliciting from '../views/homeList/soliciting'  //求租
import askBuy from '../views/homeList/askBuy'  //求购
import circle from '../views/homeList/circle'  //楼市圈
import live from '../views/homeList/live'  //楼市圈
import abulk from '../views/homeList/abulk'  //团购
import abulkDetail from '../views/abulkDetail'  //团购
import ranking from '../views/homeList/ranking'  //楼市圈
import record from '../views/homeList/record'  //楼市圈
import chatRoom from '../views/chatRoom'  //聊天室
import VR from '../views/vr'  //房间vr

Vue.use(VueRouter)

const routes = [
  {
    path: '/',
    name: 'Home',
    component: Home,

  },
  //登录界面
  {
    path: '/Login',
    name: 'Login',
    component: Login
  },
  //新房页面
  {
    path: '/newHouse',
    name: 'newHouse',
    component: newHouse
  },
    //二手房页面
    {
      path: '/twoHouse',
      name: 'twoHouse',
      component: twoHouse
    },
      //出租房页面
      {
        path: '/rent',
        name: 'rent',
        component: rent
      },
  //新房详情
  {
    path: '/Detail/:id',
    name: 'Detail',
    component: Detail
  },
   //新房地图详情
   {
    path: '/map',
    name: 'map',
    component: map
  },
  //消息页面
  {
    path: '/message',
    name: 'message',
    component: message
  },
  //求租页面
  {
    path: '/soliciting',
    name: 'soliciting',
    component: soliciting
  },
  //聊天页面
  {
    path: '/chatRoom',
    name: 'chatRoom',
    component: chatRoom
  },
  //求购页面
  {
    path: '/askBuy',
    name: 'askBuy',
    component: askBuy
  },
  //楼市圈页面
  {
    path: '/circle',
    name: 'circle',
    component: circle
  },
  //直播页面
  {
    path: '/live',
    name: 'live',
    component: live
  },
  //团购页面
  {
    path: '/abulk',
    name: 'abulk',
    component: abulk
  },
  //团购详情
  {
    path: '/abulkDetail/:id',
    name: 'abulkDetail',
    component: abulkDetail
  },
  //排行榜页面
  {
    path: '/ranking',
    name: 'ranking',
    component: ranking
  },
  //战绩页面
  {
    path: '/record',
    name: 'record',
    component: record
  },
  //VR页面
  {
    path: '/VR/:id',
    name: 'VR',
    component: VR
  },
]

const router = new VueRouter({
  mode: 'history',
  base: process.env.BASE_URL,
  routes
})

export default router
